package com.hytc.mymall.pager;

import android.content.Context;
import android.content.res.Resources;
import android.widget.TextView;

import com.hytc.mymall.R;
import com.hytc.mymall.base.BasePager;
import com.hytc.mymall.bean.HomeInfoBean;


/**
 * Created by Administrator on 2016/12/1.
 */

public class pager5 extends BasePager
{
    private TextView tv_date;
    private TextView tv_loveamount12;
    private TextView tv_loveamount24;
    private TextView tv_loveamount6;

    public pager5(final Context context, final int n, final HomeInfoBean.HomeInfo homeInfo) {
        super(context, n, homeInfo);
    }

    @Override
    public void initData() {
        super.initData();
        final HomeInfoBean.Home7 home7 = this.homeinfo.home7;
        if (home7 == null) {
            return;
        }
        try {
            this.tv_date.setText((CharSequence)(String.valueOf(this.context.getResources().getString(R.string.reward_time)) + home7.yesterday));
            this.tv_loveamount6.setText((CharSequence)home7.loveamount6);
            this.tv_loveamount12.setText((CharSequence)home7.loveamount12);
            this.tv_loveamount24.setText((CharSequence)home7.loveamount24);
        }
        catch (Resources.NotFoundException ex) {
            ex.printStackTrace();
        }
    }

    @Override
    public void initView() {
        super.initView();
        this.tv_date = (TextView)this.rootView.findViewById(R.id.tv_page5_date);
        this.tv_loveamount6 = (TextView)this.rootView.findViewById(R.id.tv_page5_loveamount6);
        this.tv_loveamount12 = (TextView)this.rootView.findViewById(R.id.tv_page5_loveamount12);
        this.tv_loveamount24 = (TextView)this.rootView.findViewById(R.id.tv_page5_loveamount24);
    }
}

